using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Nihonaid.classes;
using System.Collections;
using Nihonaid.Properties;

namespace Nihonaid
{
    public partial class UserProgressForm : Form
    {
        public UserProgressForm()
        {
            InitializeComponent();
        }

        private void UserProgressForm_FormClosed(object sender, FormClosedEventArgs e)
        {
            Program.learning_form.Show();
        }

        private void UserProgressForm_Load(object sender, EventArgs e)
        {
            pgHiragana.Value = Program.queue.LearningItemProgress(LearningItem.QuestionType.HiraganaReading);
            pgKatakana.Value = Program.queue.LearningItemProgress(LearningItem.QuestionType.KatakanaReading);
            pgKanji.Value = Program.queue.LearningItemProgress(LearningItem.QuestionType.KanjiMeaning);
            pgVocabulary.Value = Program.queue.LearningItemProgress(LearningItem.QuestionType.KanjiWordKana);
            pgOverall.Value = Program.queue.LearningItemProgress(LearningItem.QuestionType.EveryType);

            int days = Convert.ToInt32(Math.Ceiling((double)Program.queue.learning_queue.Count / Configuration.item_treshold));
            lblEstimatedCoverageTime.Text = "At this rate, you will learn all the items within the next " + days + " days.";
        }
    }
}